<%-- 
    Document   : StudentsJSP
    Created on : 24.04.2012, 09:24:07
    Author     : tamara
--%>

<%@page import="model.Cocktail"%>
<%@page import="java.util.ArrayList"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <link rel="stylesheet" type="text/css" href="css/main.css">
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Cocktails</title>
    </head>
    <body>
        <div class="container">
            <h1>Cocktails</h1>
            <br/>
            <INPUT type=button VALUE="back" onClick="history.back()">

            <form name ="recipe" action="RecipeManagerServlet">
                Please choose a Cocktail: 
                <select name="cb_cocktail" size="1">
                    <%
                        ArrayList<Cocktail> cocktails = (ArrayList<Cocktail>) request.getAttribute("cocktails");

                        for (Cocktail cocktail : cocktails) {
                            out.println("<option>" + cocktail.getCocktailname() + "</option>");;
                        }
                    %>
                </select>
                <input type="submit" value="recipe" name="btSubmit"> </input>
            </form>
        </div>
    </body>
</html>
